package top.continew.admin.generator.model.req;

import jakarta.validation.constraints.*;

import lombok.Data;

import io.swagger.v3.oas.annotations.media.Schema;

import org.hibernate.validator.constraints.Length;
import java.io.Serial;
import java.io.Serializable;
import java.time.*;

/**
 * 省区信息创建或修改参数
 *
 * @author jiangjun
 * @since 2025/06/24 10:40
 */
@Data
@Schema(description = "省区信息创建或修改参数")
public class ProvinceDivisionsReq implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 区域编码
     */
    @Schema(description = "区域编码")
    @NotBlank(message = "区域编码不能为空")
    @Length(max = 6, message = "区域编码长度不能超过 {max} 个字符")
    private String code;

    /**
     * 区域名称
     */
    @Schema(description = "区域名称")
    @NotBlank(message = "区域名称不能为空")
    @Length(max = 50, message = "区域名称长度不能超过 {max} 个字符")
    private String name;

    /**
     * 简称
     */
    @Schema(description = "简称")
    @Length(max = 10, message = "简称长度不能超过 {max} 个字符")
    private String shortName;

    /**
     * 类型
     */
    @Schema(description = "类型")
    @NotBlank(message = "类型不能为空")
    @Length(max = 64, message = "类型长度不能超过 {max} 个字符")
    private String type;
}